Support __XEN_INTERFACE_VERSION__ defined to the empty string.
authorcl349@firebug.cl.cam.ac.uk <cl349@firebug.cl.cam.ac.uk>
Thu, 6 Apr 2006 23:32:54 +0000 (00:32 +0100)
committercl349@firebug.cl.cam.ac.uk <cl349@firebug.cl.cam.ac.uk>
Thu, 6 Apr 2006 23:32:54 +0000 (00:32 +0100)
This can happen when building Linux with an old .config file which
doesn't have a value for CONFIG_XEN_INTERFACE_VERSION.

Signed-off-by: Christian Limpach <Christian.Limpach@cl.cam.ac.uk>
xen/include/public/xen-compat.h

index c4f235095d08cadaec8edb61a6260532c2ff5ced..4ef17bbaa8d1889ff12cfd80fc3de79a461ae5e1 100644 (file)
 #if defined(__XEN__)
 /* Xen is built with matching headers and implements the latest interface. */
 #define __XEN_INTERFACE_VERSION__ __XEN_LATEST_INTERFACE_VERSION__
-#elif !defined(__XEN_INTERFACE_VERSION__)
+#elif (__XEN_INTERFACE_VERSION__ - 0) == 0
 /* Guests which do not specify a version get the legacy interface. */
+#ifdef __XEN_INTERFACE_VERSION__
+#undef __XEN_INTERFACE_VERSION__
+#endif
 #define __XEN_INTERFACE_VERSION__ 0x00000000
 #endif